/** When your routing table is too long, you can split it into small modules**/

import Layout from '@/layout'

const transactRecords = {
  path: '/generaLedger',
  component: Layout,
  redirect: 'noRedirect',
  name: '总账',
  alwaysShow: true,
  meta: {
    title: '总账',
    icon: 'clipboard',
    roles: ['/generaLedger/totalRevenue', '/generaLedger/transaction', '/generaLedger/payment', '/generaLedger/businessRecon']
  },
  children: [
    {
      path: 'totalRevenue',
      component: () => import('@/views/generaLedger/totalRevenue/index'),
      name: 'totalRevenue',
      meta: { title: '总收入对账', noCache: true, roles: ['/generaLedger/totalRevenue'] }
    },
    {
      path: 'totalRevenueDetail',
      component: () => import('@/views/generaLedger/totalRevenue/totalRevenueDetail/index'),
      name: 'totalRevenueDetail',
      hidden: true,
      meta: { title: '详情', noCache: true }
    },
    {
      path: 'revenueDetail',
      component: () => import('@/views/generaLedger/totalRevenue/revenueDetail/index'),
      name: 'revenueDetail',
      hidden: true,
      meta: { title: '详情', noCache: true }
    },
    {
      path: 'transaction',
      component: () => import('@/views/generaLedger/transaction/index'),
      name: 'transaction',
      meta: { title: '按交易类型对账', noCache: true, roles: ['/generaLedger/transaction'] }
    },
    {
      path: 'payment',
      component: () => import('@/views/generaLedger/payment/index'),
      name: 'payment',
      meta: { title: '按支付方式对账', noCache: true, roles: ['/generaLedger/payment'] }
    },
    {
      path: 'businessRecon',
      component: () => import('@/views/generaLedger/businessRecon/index'),
      name: 'businessRecon',
      meta: { title: '按业务类型对账', noCache: true, roles: ['/generaLedger/businessRecon'] }
    }
  ]
}

export default transactRecords
